package org.fing.edu.uy.esbadp.admServices.mbean;

import java.sql.SQLException;
import java.util.List;

import org.fing.edu.uy.esbadp.core.entity.DMRegisteredService;
import org.fing.edu.uy.esbadp.core.entity.KeyValuePair;
import org.fing.edu.uy.esbadp.core.entity.MetaDataConfig;


public interface EsbAdmServicesMBean {

	public List<DMRegisteredService> getEquivalentsServices(Long serviceId) throws SQLException ;
	
	public List<DMRegisteredService> getAllVirtualServices() throws SQLException;	
	
    public int persistVirtualService(DMRegisteredService virtualService) throws SQLException;
	
	public void persistVirtualServiceMetadata(MetaDataConfig meta , Long serviceID) throws SQLException;	
     
    public void persistEquivVirtualServices(List<DMRegisteredService> equiv, Long serviceID) throws SQLException;
    
    public List<DMRegisteredService> getAllEquivVirtualServices(Long serviceID) throws SQLException;
	
	public DMRegisteredService getVirtualService(String endpointUrl) throws SQLException;
	
	public DMRegisteredService getVirtualService(Long serviceID) throws SQLException;	
	
	public MetaDataConfig getVirtualServiceMetadata(Long serviceID) throws SQLException;
	
	public int deleteVirtualServiceMetadata(String metaKey , Long serviceID) throws SQLException;
	
	public int deleteVirtualService(Long serviceID) throws SQLException;
	
	public int updateService(DMRegisteredService virtualService) throws SQLException;
	
	public int updateMetadata(KeyValuePair meta, Long serviceID) throws SQLException;

	public int deleteEquivRelation(Long serviceID) throws SQLException;
	
	public void saveToCanonicalXSL(String xsl , Long serviceID);
	
	public void saveFromCanonicalXSL(String xsl , Long serviceID);
	
	public String getToCanonicalXSL(Long serviceID);
	
	public String getFromCanonicalXSL(Long serviceID);
	
	public void reloadAdpActions();
	
	public void reloadAdpServiceRequirements();
	
	public void reloadAdpMonitorMechanism();
	
	public void preloadStubEGovServices(String hostName) throws SQLException;
	
}
 